package com.gz.utils;

public class DistanceUtil {
    /**
     * 获取最短的距离
     * @param lat
     * @param lon
     * @param initlat
     * @param initlon
     * @return
     */
    public static Double GetShotLocal(Double lat, Double lon, Double initlat,Double initlon) {
        Double x = (initlat - lat) * (initlat - lat);
        Double y = (initlon - lon) * (initlon - lon);
        Double z = Math.sqrt(x + y);
        return z;
    }
}
